drivers: flash: nrf_qspi_nor: Prevent CPU hang when XIP is re-enabled#88967
Merged
kartben merged 1 commit intozephyrproject-rtos:mainfrom Apr 25, 2025
Merged
drivers: flash: nrf_qspi_nor: Prevent CPU hang when XIP is re-enabled#88967kartben merged 1 commit intozephyrproject-rtos:mainfrom
kartben merged 1 commit intozephyrproject-rtos:mainfrom
Conversation
Add a simple non-XIP transaction before deactivating the QSPI after a XIP transaction is performed. This prevents a CPU hang from occuring when another XIP transaction is attempted after the QSPI is activated again. Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
nordicjm
approved these changes
Apr 23, 2025
Comment on lines
+1363
to
+1372
| /* It turns out that when the QSPI peripheral is deactivated | ||
| * after a XIP transaction, it cannot be later successfully | ||
| * reactivated and an attempt to perform another XIP transaction | ||
| * results in the CPU being hung; even a debug session cannot be | ||
| * started then and the SoC has to be recovered. | ||
| * As a workaround, at least until the cause of such behavior | ||
| * is fully clarified, perform a simple non-XIP transaction | ||
| * (a read of the status register) before deactivating the QSPI. | ||
| * This prevents the issue from occurring. | ||
| */ |
Contributor
There was a problem hiding this comment.
this seems like the issue I observed/reported years ago on nrf52840...
de-nordic
approved these changes
Apr 23, 2025
rghaddab
approved these changes
Apr 23, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a simple non-XIP transaction before deactivating the QSPI after a XIP transaction is performed. This prevents a CPU hang from occuring when another XIP transaction is attempted after the QSPI is activated again.